<#include "COMMON_HEAD.ftl">
package ${basePackage}.controller;

import com.cosmetic.core.service.BaseService;
import com.cosmetic.core.controller.BaseController;
import ${basePackage}.entity.${entityName};
import ${basePackage}.service.${entityName}Service;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

<#include "COMMON_MIDDLE.ftl">
@RestController
@RequestMapping("/${entityNameLower}s")
public class ${entityName}Controller extends BaseController<${entityName}, ${key.entityType}> {

    @Autowired
    private ${entityName}Service ${entityNameLower}Service;

    @Override
    public BaseService getService() {
        return ${entityNameLower}Service;
    }
}
